//
// C++ Interface: Query
//
// Description:
//
//
// Author: Kristina Bennett <kls93@caip.rutgers.edu>, (C) 2008
//
// Copyright: See COPYING file that comes with this distribution
//
//
#ifndef QUERY_H
#define QUERY_H

#include <vector>
#include <string>
#include "GameState.h"

using namespace std;
using namespace Card;

namespace Query {

  vector<int> FourCardValues(const CCardStack& hand);
  CCardStack maxValueCards(const CCardStack& pack, eSuit suit);
  CCardStack minValueCards(const CCardStack& pack, eSuit suit);
  float expectedValue(const CCardStack& pack, eSuit suit);
  int gainFromCard(CCardStack& hand, const CCard& card, int discard);
  int maxGainFromCard(CCardStack& hand, const CCard& card);
  int RandomChoice(int numChoices);
  int maxValue(const vector<int>& values);
  int maxValue(const int* array, int length);
  int maxValueIndex(const vector<int>& values);
  int maxValueIndex(const int* array, int length);
  CCard minValueCard(const CCardStack& pack);
  int minValue(const int* array, int length);
  int minValueIndex(const int* array, int length);
  int minValueIndex(const CCardStack& cards);
  bool lessThan(const CCard& l, const CCard& r);
  bool evalConjunction(bool* boolArray, int arraySize);
  int majority(int* indexArray, int arraySize);
  bool isValid(const Move& move);
  int factorial(int x);
  int combinations(int n, int k);  //
  int choose(int n, int k);
  
  void debugOut(const string& line, int debugLevel);
  void debugValue(int value, int debugLevel);
  
}

#endif // QUERY_H
